const mongoose = require('mongoose');
const technicianSchema = new mongoose.Schema({
    name: {
        type: String,
        required: true,
        comment:'名称'
    },
    jobNumber:{
        type: String,
        required: true,
        comment:'工号'
    },
    phone:{
        type: String,
        required: true,
        comment:'电话'
    },
    imageUrls: {
        type: [String],
        comment:'照片 默认首图第0张'
    },
    status:{
        type: String,
        default:'1',
        comment:'1/启用 0/停用'
    },
    skill:{
        type: String,
        comment:'技能'
    },
    notes: {
        type: String,
        comment:'备注 [薪资 籍贯 年龄 身高 紧急联系人]'
    },
    created_at: {
        type: Date,
        default: Date.now,
    },
    updated_at: {
        type: Date,
        default: Date.now,
    }
});

const Technician = mongoose.model('Technician', technicianSchema);

module.exports = Technician;